#include <gtest/gtest.h>  // googletest header file

#include "person.h"

TEST(Person, should_create_a_person_when_use_new_person_function)
{
    int age = 18;
    char name[MAX_NAME_LENGTH] = "zhangsan";
    
    Person *zhangsan =(Person *)malloc(sizeof(Person));
    Person_Init(zhangsan, age, name);

    ASSERT_EQ(zhangsan->age, 18);
    ASSERT_STREQ(zhangsan->name, "zhangsan");

    char introduce[MAX_INTRODUCE_LENGTH];

    zhangsan->Introduce(zhangsan, introduce);
    delete zhangsan;

}